package com.itttq.sc.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.itttq.sc.mapper.IRiverMapper;
import com.itttq.sc.po.RiverPo;

@Service
public class RiverService {
	@Autowired
	private IRiverMapper riverMapper;
	
	public RiverPo getRiver(int id) {
		return riverMapper.findRiver(id);
	}

	public List<RiverPo> getRivers(RiverPo river) {
		return riverMapper.findRivers(river);
	}

	public void delRiver(int id) {
		riverMapper.deleteRiver(id);
	}

	public void addRiver(RiverPo river) {
		riverMapper.insertRiver(river);
	}
	
	public void updateRiver(RiverPo river) {
		riverMapper.updateRiver(river);
	}
}
